import com.itheima.reggie.utils.SMSUtils;
import com.itheima.reggie.utils.ValidateCodeUtils;
import org.apache.tomcat.util.buf.Utf8Decoder;
import org.junit.jupiter.api.Test;

public class demo01 {
    /**
     * 测试阿里云短信验证码
     */
    @Test
    public   void testMsg() throws Exception {
        String code = ValidateCodeUtils.generateValidateCode4String(4);
        System.out.println(code);
//        SMSUtils smsUtils = new SMSUtils();
//        smsUtils.sendMessage("阿里云短信测试","SMS_154950909","15234701410","1234");
        SMSUtils.sendMessage("阿里云短信测试","SMS_154950909","15234701410",code);
    }
}
